//
//  DBOperation.h
//  LFCWarmSystem
//
//  Created by 李福才 on 16/5/4.
//  Copyright © 2016年 李福才. All rights reserved.
//

#import <Foundation/Foundation.h>
#import "FMDatabase.h"
#import "FMDatabaseQueue.h"
#import "ModelPSW.h"

@interface DBOperation : NSObject

@property(nonatomic,retain)FMDatabase *selfdb;
@property(nonatomic,retain)FMDatabaseQueue *dbQueue;
@property(nonatomic,assign)sqlite3 *db;

+(id)getDBOperateInstance;
+(BOOL)checkDataBase;

//主机账号
-(void)insertMainAccountWithModel:(ModelMainPhone *)model;
-(void)deleteMainAccountWithModel:(ModelMainPhone *)model;
-(void)updateMainAccountWithModel:(ModelMainPhone *)model;
-(NSMutableArray *)selectMainAccountAll;
//-(void)changeMainAccountWithModel:(ModelMainPhone *)model;
//主机密码
-(void)insertPassWordWithModel:(ModelPSW *)model;
-(void)insertPassWordWithString:(NSString *)psw;
-(void)deletePassWordWithModel:(ModelPSW *)model;
-(void)deletePassWord;
-(NSString *)selectPassWord;
@end
